/**
 * 自动生成！请勿修改！
 */
import { command } from '../core/command';

class CO2Sensor {
    constructor(opt = {}) {
        const { device, to, ...opts } = opt;

        this.device = device || {};
        this.opts = opts || {};
        this._to = to;
    }

    get categoryCode() {
        return '020010003';
    }

    get categoryName() {
        return '\u4e8c\u6c27\u5316\u78b3\u4f20\u611f\u5668';
    }

    getAlarmStatus(params) {
        return command({
            method: 'getAlarmStatus',
            methodId: 'pUXSye6C',
            params,
            to: this.to?.[this.i] || this.to,
        });
    }

    getAlarmThreshold(params) {
        return command({
            method: 'getAlarmThreshold',
            methodId: 'ppOcvgaU',
            params,
            to: this.to?.[this.i] || this.to,
        });
    }

    getConcentrationValue(params) {
        return command({
            method: 'getConcentrationValue',
            methodId: 'pZKCf6sA',
            params,
            to: this.to?.[this.i] || this.to,
        });
    }

    setAlarmThreshold(params) {
        return command({
            method: 'setAlarmThreshold',
            methodId: 'pex0Jzjw',
            params,
            to: this.to?.[this.i] || this.to,
        });
    }
}

export default CO2Sensor;
